<?php declare(strict_types=1);
/**
 * @author      xianganyall <xianganyall@gmail.com>
 * @copyright   2023-2025 owner
 **/

namespace Srv\Apps\Apis\Common\DefCtl;

final class DefEmailCategoryCtl extends DefAbstract
{
    private const TABLE_NAME                        = 'def_email_category';
    private const FIELD_ID                          = 'demc_id';
    private const FIELD_KEY                         = 'demc_key';
    private const FIELD_NAME                        = 'demc_name';
    public const EXT_NAME                           = 'name';
    public const KEY_EMAIL_BIND_CODE                = 'email_bind_code';                // 绑定邮箱
    public const KEY_EMAIL_RESET_PASSWORD           = 'email_reset_password';           // 重置密码
    public const KEY_EMAIL_FORGET_PASSWORD          = 'email_forget_password';          // 忘记密码
    public const KEY_EMAIL_REG_CODE                 = 'email_reg_code';                 // 注册登入验证码
    public const KEY_EMAIL_BIND_ACCOUNT_OFFICIAL    = 'email_bind_account_official';    // 绑定已存在账号
    public const KEY_EMAIL_SECRET_KEY               = 'email_secret_key';               // 安全密码验证

    /**
     * @return static
     * tag
     */
    public static function tag():self
    {
        $fieldExtList   = [self::EXT_NAME => self::FIELD_NAME];
        return parent::tag()->config(self::TABLE_NAME, self::FIELD_ID, self::FIELD_KEY, $fieldExtList);
    }
}